<template>
    <div>
        <dv-active-ring-chart :config="config" style="width:200px;height:200px;margin:auto"/>
    </div>
</template>

<script>
export default {
    route: false,
    data() {
        return {
            //百分比格式
            form: [],
            config: {
                radius: 50,
                digitalFlopStyle: {
                    fontSize: 25,
                    fill: '#fff'
                },
                lineWidth: 10,
                data: []
            }
        }
    },
    async created() {
        this.form = await this.axios.get('admin/bigdata/count')

        const temp = [];
        this.form.map((item) => temp.push({name: item.name, value: item.count}))
        this.config.data = temp
    }
}
</script>

<style scoped>

</style>
